<template>
  <div>
    <span class="v-tag">{{ getLabel(value) }}</span>
  </div>
</template>

<script setup>
const props = defineProps({
  options: {
    type: Array,
    required: true,
  },
  value: {
    required: true,
  },
})

const getLabel = (value) => {
  const option = props.options.find((item) => (String(item.value)) === String(value))
  return option ? option.label : ''
}
</script>

<style scoped>
.v-tag+.v-tag {
  margin-left: 10px;
}
</style>